import Vue from 'vue'
import App from './App.vue'

import axios from 'axios'
import VueRouter from 'vue-router'
import routes from './routers'
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import 'element-ui/lib/theme-chalk/display.css'
import './assets/style.css'
import fHeader from './components/f-header'
import fFooter from './components/f-footer'
import i18n from './i18n/i18n'
import VueParticles from 'vue-particles'
import cookie from 'vue-cookie'



Vue.prototype.$ajax=axios;
Vue.use(VueRouter);
Vue.use(ElementUI);
Vue.use(VueParticles);
Vue.use(cookie);
Vue.component("f-header",fHeader);
Vue.component("f-footer",fFooter);


Vue.config.productionTip = false;


const router =new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes,
});
const originalPush = VueRouter.prototype.push;
VueRouter.prototype.push = function push(location) {
  return originalPush.call(this, location).catch(err => err)
};
Vue.use(router);

new Vue({

  router,
  i18n,
  render: h => h(App),
}).$mount('#app');
